<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>登录页</title>
</head>
<body>
<form class="form-signin" th:action="@{/login}" th:object="${user}" method="post">

    <input type="text"  th:field="*{username}"/>
    <input type="password" th:field="*{password}"/>
    <p th:if="${param.logout}" class="error-code">已成功注销</p>
    <p th:if="${param.error}" class="error-code">用户名或者密码错误</p>
    <button type="submit">登录</button>
</form>
</body>

</html>